import 'package:flutter/material.dart';
import 'package:flutter_09_game/base/widget/base_get_builder.dart';
import 'package:flutter_09_game/config/app_color.dart';
import 'package:flutter_09_game/generated/assets.dart';
import 'package:flutter_09_game/generated/locales.g.dart';
import 'package:flutter_09_game/user/app_user_manager.dart';
import 'package:flutter_09_game/widgets/appbar/common_app_bar.dart';
import 'package:flutter_09_game/widgets/btn_dropdown.dart';
import 'package:flutter_09_game/widgets/crypto_tag_selector.dart';
import 'package:flutter_09_game/widgets/image/auto_image.dart';
import 'package:flutter_09_game/widgets/tab/common_tab_bar_page.dart';
import 'package:flutter_09_game/widgets/tab/custom_tab_indicator.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:get/get.dart';

import 'profile_bet_record_logic.dart';
// getBattleRoyaleLog
class ProfileBetRecordPage extends StatelessWidget {
  ProfileBetRecordPage({super.key});

  final ProfileBetRecordLogic logic = Get.put(ProfileBetRecordLogic());

  @override
  Widget build(BuildContext context) {
    return BaseGetBuilder<ProfileBetRecordLogic>(
      appBar: CommonAppBar(
        title: LocaleKeys.betRecord.tr,
        // showBack: false,
        actions: [
          GestureDetector(
            onTap: () {
              AppUserManager().showServiceSheet();
            },
            child: AutoImage(
              Assets.commonServiceBtn,
              width: 32.w,
            ),
          ),
          10.horizontalSpace,
        ],
      ),
      // backgroundColor: ,
      builder: (_) {
        return CommonTabBarPage(
            tabIsScrollable: false,
            tabBarPadding: EdgeInsets.zero,
            labelPadding: EdgeInsets.zero,
            tabController: logic.tabController,
            indicatorSize: TabBarIndicatorSize.tab,
            backgroundColor: AppColor.navBgColor,
            // fitTabBackgroundColor: Colors.red,
            tabBarHeight: 50.w,
            // tabBarPadding: ,
            keepView: false,
            indicator: CustomTabIndicator(
              width: 98.w,
              height: 2.w,
              indicatorPadding: EdgeInsets.only(top: -4.w),
              color: AppColor.primary,
              // borderRadius: 2.w,
              isCentered: true,
            ),
            tabData: logic.tabData);
      },
    );
  }



}
